﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using HeresyManager.Comunication;

namespace HeresyManager.Careers
{
    [Serializable]
    public class Sororitas : Career
    {

        private Skill[] skills;
        private Talent[] talents;

        public override string Name
        {
            get { return "Sororitas"; }
        }

        public override IEnumerator<Comunicator> Acire(Character c)
        {

            List<Skill> skillList = new List<Skill>();

            skillList.Add(new Skills.CommonLores.CommonLoreImperialCreed(Skill.SkillLevel.Skilled));
            skillList.Add(new Skills.Literacy(Skill.SkillLevel.Skilled));
            skillList.Add(new Skills.Performers.PerformerSinger(Skill.SkillLevel.Skilled));
            skillList.Add(new Skills.SpeakLanguages.SpeakLanguageLowGothic(Skill.SkillLevel.Skilled));
            skillList.Add(new Skills.Trades.TradeCopyist(Skill.SkillLevel.Skilled));



            skills = skillList.ToArray();

            foreach (var s in skills)
            {
                var en = c.AddSkill(s, this);
                while (en.MoveNext())
                    yield return en.Current;
            }




            List<Talent> talentList = new List<Talent>();

            talentList.Add(new Talents.WeaponTraining.MeleeWeaponTrainingPrimitive());
            talentList.Add(new Talents.WeaponTraining.BasicWeaponTrainingPrimitive());
            talentList.Add(new Talents.WeaponTraining.PistolTrainingLas());
            talentList.Add(new Talents.PureFaith());

            talents = talentList.ToArray();

            foreach (var s in talents)
            {
                var en = c.AddTalent(s, this);
                while (en.MoveNext())
                    yield return en.Current;
            }

        }

        public override void DeAcire(Character c)
        {
            foreach (var s in skills)
            {
                c.RemoveSkill(s, this);
            }

            foreach (var item in talents)
            {
                c.RemoveTalent(item, this);
            }
            this.talents = null;
        }

        public override Rank[] Ranks
        {
            get { return new Rank[] { }; }
        }

        public override BackgroundPackage[] BackgroundPackages
        {
            get { return new BackgroundPackage[] { }; }
        }

        public override int[] WeaponSkillCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }

        public override int[] BalisticSkillCost
        {
            get { return new int[] { 100, 250, 500, 750 }; }
        }

        public override int[] StrengthCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }

        public override int[] ToughnessCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }

        public override int[] AgilityCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }

        public override int[] IntelligenceCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }

        public override int[] PerceptionCost
        {
            get { return new int[] { 100, 250, 500, 750 }; }
        }

        public override int[] WillpowerCost
        {
            get { return new int[] { 100, 250, 500, 750 }; }
        }

        public override int[] FellowshipCost
        {
            get { return new int[] { 250, 500, 750, 1000 }; }
        }
    }
}
